﻿/**
 * ...
 * @author George Mavchun
 */

package gui.hug;

class CookBook 
{

	public function new() 
	{
		//**********************************************************************************************
		
		var b = new LinkButton("Вперед!", 100, 300);
		b.addEventListener(MouseEvent.CLICK, function(e : MouseEvent) { trace(e.target.getLabel()); } );
		/*var button : HUGSquareButton = new HUGSquareButton("Отмена", 100, 300, Button.BLUE_BUTTON);
		button.addEventListener(MouseEvent.CLICK, function(e : MouseEvent) { trace(e.target.label); } );
		button.setWidth(200);
		button.setHeight(40);*/
		sprite.addChild(b);

		//**********************************************************************************************
		
		var b1 = new LightButton("Blue HighLight Button", 100, 340, 200, Utils.BK_COL, Utils.BLUE_BK_COL, Utils.BUT1_TXT_COL, Utils.BUT1_TXT_COL, LightButton.CENTER, 10);
		sprite.addChild(b1);
		
		//**********************************************************************************************
		
		var pag : HUGPagination = new HUGPagination(135, 100, 200, 100, HUGPagination.RECT_AS_SEL, 3, 10);
		pag.setCurPage(2);
		pag.setHeight(100);
		pag.addEventListener(Event.CHANGE, onPagination);
		sprite.addChild(pag);
		
		//**********************************************************************************************
		
		var checkBox: HUGCheckBox = new HUGCheckBox("Правильный ответ", 20, 70);
		checkBox.addEventListener(Event.CHANGE, function(e : Event) { trace(e.target.getChecked()); });
		sprite.addChild(checkBox);
		
		//**********************************************************************************************
		
		var group = new HUGRadioButtonsGroup(20, 100); 
		var radioButton1 = group.addRadioButton("Вариант 1", 0, 0); 
		var radioButton2 = group.addRadioButton("Вариант 2", 0, 20); 
		var radioButton3 = group.addRadioButton("Вариант 3", 0, 40); 
		group.setSelectedItem(radioButton2); 
		group.addEventListener(Event.CHANGE, function(e : Event) { trace(e.target.getSelectedIndex()); });
		sprite.addChild(group);  
		
		//**********************************************************************************************
		//**********************************************************************************************
		//**********************************************************************************************
		//**********************************************************************************************
		//**********************************************************************************************
		//**********************************************************************************************
		//**********************************************************************************************
		//**********************************************************************************************
		//**********************************************************************************************
	}
	
}